home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgramD2.iso / Borland / Borland C++ V5.02 / AWARE_H.PAK / DBACC.H next >
C/C++ Source or Header  |  1997-05-06  |  5KB  |  150 lines

  1. //--------------------------------------------------------
  2. // DBACC.H
  3. // Copyrights (C) 1996 Borland International
  4. // All Rights Reserved
  5. //--------------------------------------------------------
  6.  
  7. #ifndef _DBACC_H_
  8. #define _DBACC_H_
  9.  
  10. #include <owl/pch.h>
  11. #include <owl/applicat.h>
  12. #include <vdbt/bdto.h>
  13. #include <bivbx.h>
  14. #include <owl/vbxctl.h>
  15. #include <vdbt/dbpme.h>
  16.  
  17.  
  18. //
  19. // Mangle the class and function names so we can have mulitpale versions of the
  20. // same classes and functions in one .LIB file.
  21. //
  22. #if defined( __DLL__ ) && ! defined( __FLAT__ )
  23. #  if defined( _RTLDLL )
  24. #    define TDBBatchMove   dTDBBatchMove
  25. #    define TDBDatabase    dTDBDatabase
  26. #    define TDBDataSource  dTDBDataSource
  27. #    define TDBQuery       dTDBQuery
  28. #    define TDBStoredProc  dTDBStoredProc
  29. #    define TDBTable       dTDBTable
  30. #  else _RTLDLL
  31. #    define TDBBatchMove   uTDBBatchMove
  32. #    define TDBDatabase    uTDBDatabase
  33. #    define TDBDataSource  uTDBDataSource
  34. #    define TDBQuery       uTDBQuery
  35. #    define TDBStoredProc  uTDBStoredProc
  36. #    define TDBTable       uTDBTable
  37. #  endif _RTLDLL
  38. #elif defined( _RTLDLL )
  39. #  define TDBBatchMove   iTDBBatchMove
  40. #  define TDBDatabase    iTDBDatabase
  41. #  define TDBDataSource  iTDBDataSource
  42. #  define TDBQuery       iTDBQuery
  43. #  define TDBStoredProc  iTDBStoredProc
  44. #  define TDBTable       iTDBTable
  45. #endif
  46.  
  47. class _DBAWARECLASS TDBDataSource : public TVbxControl, public TDataSource {
  48.   private: // Don't let anyone use these
  49.     TDBDataSource& operator=(TDBDataSource&);
  50.     TBDDataSource(TDBDataSource&);
  51.  
  52.   public:
  53.     TDBDataSource( TWindow *parent, int id, LPCSTR title
  54.              , int x=0, int y=0, TModule *module=0 )
  55.              : TVbxControl( parent, id, "BDT52ACC.VBX", "TDataSource"
  56.                           , title, x, y, 0, 0, 0, 0, module ) {}
  57.  
  58.     TDBDataSource( TWindow *parent, int resourceId, TModule *module=0 )
  59.                  : TVbxControl( parent, resourceId, module ) {}
  60.  
  61.     bool Create();
  62. };
  63.  
  64. class _DBAWARECLASS TDBTable : public TVbxControl, public TTable {
  65.   private: // Don't let anyone use these
  66.     TDBTable& operator=(TDBTable&);
  67.     TBDTable(TDBTable&);
  68.  
  69.   public:
  70.     TDBTable( TWindow *parent, int id, LPCSTR title
  71.             , int x=0, int y=0, TModule *module=0 )
  72.             : TVbxControl( parent, id, "BDT52ACC.VBX", "TTable"
  73.                          , title, x, y, 0, 0, 0, 0, module ) {}
  74.  
  75.     TDBTable( TWindow *parent, int resourceId, TModule *module=0 )
  76.             : TVbxControl( parent, resourceId, module ) {}
  77.  
  78.     bool Create();
  79. };
  80.  
  81. class _DBAWARECLASS TDBQuery : public TVbxControl, public TQuery {
  82.   private: // Don't let anyone use these
  83.     TDBQuery& operator=(TDBQuery&);
  84.     TBDQuery(TDBQuery&);
  85.  
  86.   public:
  87.     TDBQuery( TWindow *parent, int id, LPCSTR title
  88.             , int x=0, int y=0, TModule *module=0 )
  89.             : TVbxControl( parent, id, "BDT52ACC.VBX", "TQuery"
  90.                          , title, x, y, 0, 0, 0, 0, module ) {}
  91.  
  92.     TDBQuery( TWindow *parent, int resourceId, TModule *module=0 )
  93.             : TVbxControl( parent, resourceId, module ) {}
  94.  
  95.     bool Create();
  96. };
  97.  
  98. class _DBAWARECLASS TDBBatchMove : public TVbxControl, public TBatchMove {
  99.   private: // Don't let anyone use these
  100.     TDBBatchMove& operator=(TDBBatchMove&);
  101.     TBDBatchMove(TDBBatchMove&);
  102.  
  103.   public:
  104.     TDBBatchMove( TWindow *parent, int id, LPCSTR title
  105.                 , int x=0, int y=0, TModule *module=0 )
  106.                 : TVbxControl( parent, id, "BDT52ACC.VBX", "TBatchMove"
  107.                              , title, x, y, 0, 0, 0, 0, module ) {}
  108.  
  109.     TDBBatchMove( TWindow *parent, int resourceId, TModule *module=0 )
  110.                 : TVbxControl( parent, resourceId, module ) {}
  111.  
  112.     bool Create();
  113. };
  114.  
  115. class _DBAWARECLASS TDBDatabase : public TVbxControl, public TDatabase {
  116.   private: // Don't let anyone use these
  117.     TDBDatabase& operator=(TDBDatabase&);
  118.     TBDDatabase(TDBDatabase&);
  119.  
  120.   public:
  121.     TDBDatabase( TWindow *parent, int id, LPCSTR title
  122.                 , int x=0, int y=0, TModule *module=0 )
  123.                 : TVbxControl( parent, id, "BDT52ACC.VBX", "TDatabase"
  124.                              , title, x, y, 0, 0, 0, 0, module ) {}
  125.  
  126.     TDBDatabase( TWindow *parent, int resourceId, TModule *module=0 )
  127.                 : TVbxControl( parent, resourceId, module ) {}
  128.  
  129.     bool Create();
  130. };
  131.  
  132. class _DBAWARECLASS TDBStoredProc : public TVbxControl, public TStoredProc {
  133.   private: // Don't let anyone use these
  134.     TDBStoredProc& operator=(TDBStoredProc&);
  135.     TBDStoredProc(TDBStoredProc&);
  136.  
  137.   public:
  138.     TDBStoredProc( TWindow *parent, int id, LPCSTR title
  139.                  , int x=0, int y=0, TModule *module=0 )
  140.                  : TVbxControl( parent, id, "BDT52ACC.VBX", "TStoredProc"
  141.                               , title, x, y, 0, 0, 0, 0, module ) {}
  142.  
  143.     TDBStoredProc( TWindow *parent, int resourceId, TModule *module=0 )
  144.                  : TVbxControl( parent, resourceId, module ) {}
  145.  
  146.     bool Create();
  147. };
  148.  
  149. #endif _DBACC_H_
  150.